<!DOCTYPE HTML>
<html>
<head>
<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>科创研究成果平台</title>
<link href="css/main.css" rel="stylesheet" />
<link href="css/style.css"  rel="stylesheet" />
<link href="../bootstrap/dist/css/bootstrap.css"  rel="stylesheet" />
<script src="js/jquery-1.8.3.min.js"  type="text/javascript"></script>
<script src="js/jquery.SuperSlide.2.1.1.js" ></script>
<script type="text/javascript" src="../bootstrap/dist/js/bootstrap.js"></script>
<!--ie9以下调用-->
<!--[if lt IE 9]>
<script src="js/html5.js" ></script>
<script src="js/PIE.js"  type="text/javascript"></script>
<![endif]-->
<style type="text/css">
a{
    text-decoration : none
}
</style>
</head>
<body style="background-color: #EBEBEB">
<!--头部-->
<header>
	<div class="beijing">
		<h2 style="font-weight:bold;font-size: 18px;">
		<a href="index.html" style="text-decoration : none"><em>
		<font color="white">科创研究成果平台</font></em></a>
		</h2>
        <ul>
            <li>
                <a class="menu_1 " style="text-decoration : none" href="index.html" >首页</a>
            </li>
            <li>
                <a class="menu_1 " style="text-decoration : none" href="news.html">资讯<em></em></a>
            </li>
            <li>
                <a class="menu_1 " style="text-decoration : none" href="act.html">活动<em></em></a>
            </li>
            <li>
                <a class="menu_1 " style="text-decoration : none" href="tech.html" >技术<em></em></a>
            </li>
            <li>
                <a class="menu_1 hover" style="text-decoration : none" href="cooper.html">合作<em></em></a>
            </li>
            <li>
                <a class="menu_1 " style="text-decoration : none" href="person.html" >个人中心<em></em></a>
            </li>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               
        </ul>
		<div class="clear"></div>		
	</div>
	<div class="clear"></div>
</header>

<div class="main_banner" style="background-image: url(./img/bg-header-experts.jpg);height: 350px;">
    <div style="position: relative;top: 150px;left: 518px;">
    <h1 style="font-size: 50px;color: #fff;font-weight: 600;">热门需求</h1></div>
</div>
<!--主体-->
<div class="beijing1">
	<ul class="case">
	</ul>
</div>
</body>
</html>
<script type="text/javascript">
    $(document).ready(function () {
        $.ajax({
            url:"/requirement/search",
            type:"POST",
            dataType: "json",//预期服务器返回的数据类型
            success: function (result) {
                console.log(result);//打印
                for(var i=0;i<result.rows.length;i++){
                    var title=result.rows[i].name;
                    var id=result.rows[i].id;
                    var acttime=result.rows[i].acttime;
                    var detail=result.rows[i].detail;
                    var html=`<li>
                    <div class="case_1">
                        <h1 style="font-size: 25px;"><a style="text-decoration : none" href="cooperdetail.html?id=${id}">${title}</a></h1>
                        <span style="font-size: 16px;overflow: hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: 3; -webkit-box-orient: vertical;">需求简介：${detail}</span>
                    </div><div><button onclick="location='cooperdetail.html?id=${id}'" type="button" class="btn btn-primary">联系需求方</button></div></li>`;
                    $(".case").append(html);
                }
            }
        });
    })
</script>
<script type="text/javascript" src="js/xmsz_common.js" ></script>
